import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'

//vantui
import Vant from 'vant'
import 'vant/lib/index.css';
Vue.use(Vant);

//echarts
import * as echarts from 'echarts'
Vue.prototype.$echarts = echarts

//elementui
import ElementUI from 'element-ui'
import 'element-ui/lib/theme-chalk/index.css'
Vue.use(ElementUI)

//socketio
import VueSocketIO from 'vue-socket.io'
import SocketIO from 'socket.io-client'

Vue.use(new VueSocketIO({
  // debug:true,
  connection:SocketIO('ws://localhost:3000'),
  vuex:{}
}))

//axios
import axios from 'axios';
axios.defaults.baseURL="http://localhost:3000";
Vue.prototype.axios=axios;

//good-storage
import storage from 'good-storage'
Vue.prototype.storage=storage;

// vue-video-player
//npm install vue-video-player --save
import VideoPlayer from 'vue-video-player'
require('video.js/dist/video-js.css')
require('vue-video-player/src/custom-theme.css')
import 'videojs-contrib-hls' //单是 RTMP 的话不需要第三方库，如果是 HLS 的话需要引入videojs-contrib-hls，看具体情况而定。
Vue.use(VideoPlayer);

Vue.config.productionTip = false

new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')
